<template>
  <x-page title="推荐">
    <swiper direction="horizontal" class="text-scroll" :show-dots="true">
      <swiper-item class="swiper-demo-img" v-for="(item, index) in adList" :key="index">
        <x-img :src="item.picUrl" style="height: 165px" />
      </swiper-item>
    </swiper>
  </x-page>
</template>

<script>
import { Swiper, SwiperItem, XImg } from 'vux'
export default {
  name: 'home',
  components: { Swiper, SwiperItem, XImg },
  data () {
    return {
      adList: [
        {
          id: 1,
          picUrl: 'http://y.gtimg.cn/music/photo_new/T003R720x288M000003wlyl10esONW.jpg'
        },
        {
          id: 2,
          picUrl: 'http://y.gtimg.cn/music/photo_new/T003R720x288M000004JKrPO4SkNGH.jpg'
        },
        {
          id: 3,
          picUrl: 'http://y.gtimg.cn/music/photo_new/T003R720x288M000003wlyl10esONW.jpg'
        }
      ]
    }
  },
  created(){
    console.log(123)
  }
}
</script>

<style scoped>
.ui-slider{
  width: 414px;
}
</style>
